import React, { Component,useState } from 'react';
import {   Button } from 'antd';
import 'antd/dist/antd.css'

const App = (e) => {
    const [isModalVisible, setIsModalVisible] = useState(false);
  
    const showModal = () => {
      e.history.replace(`/home/fenlei/typetwo?typenoe=${e.record}`)
      setIsModalVisible(true);
    };
  
  
    return (
      <>
        <Button type="primary" onClick={showModal}>
          {e.name}
        </Button>
      </>
    );
  };
class index extends Component {
    render() {
        const {record ,name,history}=this.props
        return (
            <div>
                <App history={history} record={record} name={name}/>
            </div>
        );
    }
}

export default index;